home *** CD-ROM | disk | FTP | other *** search
/ 9-Digit Zip Code Directory / 9-Digit Zip Code Directory (American Business Information) (ABIZIP-12).ISO / z4src.zip / PROCESS.H < prev    next >
C/C++ Source or Header  |  1993-11-23  |  4KB  |  145 lines

  1. /***
  2. *process.h - definition and declarations for process control functions
  3. *
  4. *   Copyright (c) 1985-1992, Microsoft Corporation.  All rights reserved.
  5. *
  6. *Purpose:
  7. *   This file contains the declarations and definitions for the
  8. *   spawnxx, execxx, and various other process control routines.
  9. *
  10. ****/
  11.  
  12. #ifndef _INC_PROCESS
  13.  
  14. #ifdef __cplusplus
  15. extern "C" {
  16. #endif 
  17.  
  18. #if (_MSC_VER <= 600)
  19. #define __cdecl     _cdecl
  20. #define __far       _far
  21. #define __near      _near
  22. #endif 
  23.  
  24. /* mode values for spawnxx routines
  25.  * (only P_WAIT and P_OVERLAY are supported on MS-DOS)
  26.  */
  27.  
  28. #ifndef _MT
  29. extern int __near __cdecl _p_overlay;
  30. #endif 
  31.  
  32. #define _P_WAIT     0
  33. #define _P_NOWAIT   1
  34. #ifdef _MT
  35. #define _P_OVERLAY  2
  36. #else 
  37. #define _P_OVERLAY  _p_overlay
  38. #endif 
  39. #define _OLD_P_OVERLAY  2
  40. #define _P_NOWAITO  3
  41. #define _P_DETACH   4
  42.  
  43.  
  44. /* function prototypes */
  45.  
  46. #ifdef _MT
  47. int __cdecl _beginthread(void(__cdecl *)(void *),
  48.     void *, unsigned, void *);
  49. void __cdecl _endthread(void);
  50. #endif 
  51. void __cdecl abort(void);
  52. void __cdecl _cexit(void);
  53. void __cdecl _c_exit(void);
  54. #ifndef _WINDOWS
  55. int __cdecl _execl(const char *, const char *, ...);
  56. int __cdecl _execle(const char *, const char *, ...);
  57. int __cdecl _execlp(const char *, const char *, ...);
  58. int __cdecl _execlpe(const char *, const char *, ...);
  59. int __cdecl _execv(const char *,
  60.     const char * const *);
  61. int __cdecl _execve(const char *,
  62.     const char * const *, const char * const *);
  63. int __cdecl _execvp(const char *,
  64.     const char * const *);
  65. int __cdecl _execvpe(const char *,
  66.     const char * const *, const char * const *);
  67. #endif 
  68. #ifndef _WINDLL
  69. void __cdecl exit(int);
  70. void __cdecl _exit(int);
  71. #endif 
  72. int __cdecl _getpid(void);
  73. #ifndef _WINDOWS
  74. int __cdecl _spawnl(int, const char *, const char *,
  75.     ...);
  76. int __cdecl _spawnle(int, const char *, const char *,
  77.     ...);
  78. int __cdecl _spawnlp(int, const char *, const char *,
  79.     ...);
  80. int __cdecl _spawnlpe(int, const char *, const char *,
  81.     ...);
  82. int __cdecl _spawnv(int, const char *,
  83.     const char * const *);
  84. int __cdecl _spawnve(int, const char *,
  85.     const char * const *, const char * const *);
  86. int __cdecl _spawnvp(int, const char *,
  87.     const char * const *);
  88. int __cdecl _spawnvpe(int, const char *,
  89.     const char * const *, const char * const *);
  90. int __cdecl system(const char *);
  91. #endif 
  92.  
  93. #ifndef __STDC__
  94. /* Non-ANSI names for compatibility */
  95.  
  96. #define P_WAIT      _P_WAIT
  97. #define P_NOWAIT    _P_NOWAIT
  98. #define P_OVERLAY   _P_OVERLAY
  99. #define OLD_P_OVERLAY   _OLD_P_OVERLAY
  100. #define P_NOWAITO   _P_NOWAITO
  101. #define P_DETACH    _P_DETACH
  102.  
  103. #ifndef _WINDOWS
  104. int __cdecl execl(const char *, const char *, ...);
  105. int __cdecl execle(const char *, const char *, ...);
  106. int __cdecl execlp(const char *, const char *, ...);
  107. int __cdecl execlpe(const char *, const char *, ...);
  108. int __cdecl execv(const char *,
  109.     const char * const *);
  110. int __cdecl execve(const char *,
  111.     const char * const *, const char * const *);
  112. int __cdecl execvp(const char *,
  113.     const char * const *);
  114. int __cdecl execvpe(const char *,
  115.     const char * const *, const char * const *);
  116. #endif 
  117. int __cdecl getpid(void);
  118. #ifndef _WINDOWS
  119. int __cdecl spawnl(int, const char *, const char *,
  120.     ...);
  121. int __cdecl spawnle(int, const char *, const char *,
  122.     ...);
  123. int __cdecl spawnlp(int, const char *, const char *,
  124.     ...);
  125. int __cdecl spawnlpe(int, const char *, const char *,
  126.     ...);
  127. int __cdecl spawnv(int, const char *,
  128.     const char * const *);
  129. int __cdecl spawnve(int, const char *,
  130.     const char * const *, const char * const *);
  131. int __cdecl spawnvp(int, const char *,
  132.     const char * const *);
  133. int __cdecl spawnvpe(int, const char *,
  134.     const char * const *, const char * const *);
  135. #endif 
  136.  
  137. #endif 
  138.  
  139. #ifdef __cplusplus
  140. }
  141. #endif 
  142.  
  143. #define _INC_PROCESS
  144. #endif 
  145.